<?php

namespace App\Http\Controllers\Api\V1\Resources;

use Illuminate\Http\Resources\Json\JsonResource;

class MerchatResource extends JsonResource
{
    public function toArray($request)
    {
    	$resource = $this->resource;
    	
        return [
        	'id' => (int)$resource->id,
            'name' => $resource->name,
            'house_number' =>$resource->house_number,
            'desc' =>$resource->desc,
            'logo' => img_path($resource->logo),
	        'created_at' => (string)$resource->created_at,
        ];
    }
}
